﻿using Restful_Api.Entities;
using Restful_Api.ValidationAttributes;
using System;
using System.Collections.Generic;
using System.ComponentModel.DataAnnotations;
using System.Linq;
using System.Threading.Tasks;

namespace Restful_Api.Models
{
    [EmployeeAddDtoFirstNameAttribute(ErrorMessage = "员工编号不可以等于名!!!")]
    public abstract class EmployeeAddorUpdateBase 
    {
        [Display(Name = "员工号")]
        [Required(ErrorMessage = "{0}是必须的")]
        public string EmployeeNo { get; set; }
        [Display(Name = "性")]
        [Required(ErrorMessage = "{0}是必须的")]
        public string FistName { get; set; }
        [Display(Name = "名")]
        public string LastName { get; set; }
        [Display(Name = "性别")]
        public Gender Gender { get; set; }
        [Display(Name = "出生日期")]
        public DateTime DateOfBirth { get; set; }
       
    }
}
